Platform Explorer / Nuxeo Platform 2021.52

Operation Context.GetEmailsWithPermissionOnDoc (Get Principal Emails)

Description

Fetch the principal emails that have a given permission on the input document and then set them in the context under the given key variable name. The operation returns the input document. You can later use the list of principals set by this operation on the context from another operation. The 'key' argument represents the variable name and the 'permission' argument the permission to check. If the 'ignore groups' argument is false then groups are recursively resolved, extracting user members of these groups. Be warned that this may be a very consuming operation.
    Note that
  • groups are not included
  • the list pushed into the context is a string list of emails.
Operation id Context.GetEmailsWithPermissionOnDoc
AliasesDocument.GetPrincipalEmails
Category Users & Groups
Label Get Principal Emails
Requires
Since

Parameters

Name Description Type Required Default value
permission string yes  
variable name string yes  
ignore groups boolean no false 

Signature

Inputs document
Outputs document

Implementation Information

Implementation Class Class: org.nuxeo.ecm.automation.core.operations.users.GetDocumentPrincipalEmails
Contributing Component org.nuxeo.ecm.core.automation.features.operations

JSON Definition

{
  "id" : "Context.GetEmailsWithPermissionOnDoc",
  "aliases" : [ "Document.GetPrincipalEmails" ],
  "label" : "Get Principal Emails",
  "category" : "Users & Groups",
  "requires" : null,
  "description" : "Fetch the principal emails that have a given permission on the input document and then set them in the context under the given key variable name. The operation returns the input document. You can later use the list of principals set by this operation on the context from another operation. The 'key' argument represents the variable name and the 'permission' argument the permission to check. If the 'ignore groups' argument is false then groups are recursively resolved, extracting user members of these groups. Be <b>warned</b> that this may be a very consuming operation.<ul>Note that <li></li><li>groups are not included</li><li>the list pushed into the context is a string list of emails.</li></ul>",
  "url" : "Context.GetEmailsWithPermissionOnDoc",
  "signature" : [ "document", "document" ],
  "params" : [ {
    "name" : "permission",
    "description" : null,
    "type" : "string",
    "required" : true,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "variable name",
    "description" : null,
    "type" : "string",
    "required" : true,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "ignore groups",
    "description" : null,
    "type" : "boolean",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ "false" ]
  } ]
}